package com.wing.res.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.wing.res.dao.ResBenchmarkBookQualityDao;
import com.wing.res.model.entity.ResBenchmarkBookQuality;
import com.wing.res.service.ResBenchmarkBookQualityService;
import org.springframework.stereotype.Service;

import java.util.List;


/**
 * sku产品质检-ServiceImpl
 * @version 1.1.0
 * @Author hz
 * @Date 2024-09-23 20:59
 **/
@Service
public class ResBenchmarkBookQualityServiceImpl extends ServiceImpl<ResBenchmarkBookQualityDao, ResBenchmarkBookQuality> implements ResBenchmarkBookQualityService {

    /**
     * 查询基准书列表
     * @param bookId 基准书
     * @return
     */
    @Override
    public List<ResBenchmarkBookQuality> getQualityInfoBY(Long bookId) {
        QueryWrapper<ResBenchmarkBookQuality> wrapper = new QueryWrapper<ResBenchmarkBookQuality>();
        wrapper.eq("book_id", bookId);
        wrapper.eq("is_deleted", 0);
        wrapper.orderByAsc("create_time");
        return this.list(wrapper);
    }
}
